precision mediump float;
varying vec2 v_uv;
varying vec3 v_normalW;
uniform sampler2D u_s_texture;
uniform sampler2D sample[3];

void main()
{
	//gl_FragColor = vec4(1.0, 0.0, 0.0, 1.0);
	//gl_FragColor = v_color;
	
	//vec4 color = texture2D(u_s_texture, v_uv);
	//vec3 lightDirection = vec3(0.0, 0.0, -1.0);
	//gl_FragColor = vec4(lightDirection * color.xyz, color.a);
	
	/* lighting
	vec3 light = vec3(0.0, 0.0, -1.0);
	vec3 lightDirection = normalize(light);
	float diffuse = max(0.0, dot(-lightDirection, v_normalW));
	vec4 color = texture2D(u_s_texture, v_uv);
    gl_FragColor = vec4(diffuse * color.xyz, color.a);
	*/
	
	gl_FragColor = texture2D(u_s_texture, v_uv);
	
	// alpha test
	if (gl_FragColor.a < 0.5)
	{
		//discard;
	}
}
